const mongoose = require('mongoose')
const {Schema,model} = mongoose 
const chatRoomMsgSchema = new Schema({
  __v: {type: Number,required: true},
  chatRoomId:{type: String, required: true},// 聊天室id
  uid : {type: String, required: true}, // 用户id
  realname: {type: String, required: false}, // 用户昵称
  avatar_url: {type: String, required: false}, // 头像
  content : {type: String, required: true}, // 聊天记录内容
},{timestamps:true})

module.exports = model("ChatRoomMsg",chatRoomMsgSchema)